package pattern;

/**
 * Description: The state class of the the shoe
 * @author Willa
 *
 */
public class State {
	
	//The states of the shoes
	public static final int WHOLE_RELAX = 0;
	public static final int TOP_DOWN = 1;
	public static final int BOTTOM_DOWN = 2;
	public static final int INSIDE_DOWN = 3;
	public static final int OUTSIDE_DOWN = 4;
	
	public static final int TOP_INSIDE_DOWN = 5;
	public static final int TOP_OUTSIDE_DOWN = 6;
	public static final int BOTTOM_INSIDE_DOWN = 7;
	public static final int BOTTOM_OUT_DOWN = 8;
	
	public static final int WHOLE_DOWN = 9;
	
	private int current = WHOLE_RELAX;
	
	/**
	 * Description: constructor of the states
	 * @param state
	 */
	public State(int state){
		current = state;
	}
	
	/**
	 * Description: Get method of the current
	 * @return current state
	 */
	public int getState(){
		return current;
	}
	
	/**
	 * Description: Set method of current
	 * @param state
	 */
	public void setState(int state){
		
		if(state<=9&&state>=0)
			current = state;
		else current = WHOLE_RELAX;
		
	}
	/*public static void main(String args[]){
		
		System.out.println(RELAX);
		
	}*/
}